/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
package wf3.kernel;

/**
 *
 * @author romulogalindo
 */
public class TransaConsumer implements Runnable {

    private boolean live;

    public TransaConsumer(boolean live) {
        this.live = live;
    }

    @Override
    public void run() {
        while (live) {
            try {
                Object obj = TransaManager.getQuery();
                System.out.println("consumiendo:" + obj);
            } catch (Exception ep) {
                System.out.println("Error consumer:" + ep);
            }
        }
    }

}
